<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>用户注册</title>
    <link href="<c:url value='/static/style/user/regist.css'/>" rel="stylesheet" type="text/css">
    
    <script type="text/javascript" src="<c:url value='/static/jquery/jquery-1.5.1.js'/>"></script>
    <script type="text/javascript" src="<c:url value='/static/js/user/regist.js'/>"></script>
  </head>
  <body>
    <div id="divMain">
      <div id="divTitle">
        <span id="spanTitle">新用户注册</span>
      </div>
      <div id="divBody">
        <form action="<c:url value='/UserServlet'/>" method="post" id="registForm">
          <input type="hidden" name="method" value="regist"/>  
          <table id="tableForm">
            <tr>
              <td class="tdText">用户名：</td>
              <td class="tdInput">
                <input class="inputClass" type="text" name="loginname" id="loginname" value="${form.loginname }"/>
              </td>
              <td class="tdError">
                <label class="errorClass" id="loginnameError">${errors.loginname }</label>
              </td>
            </tr>
            <tr>
              <td class="tdText">登录密码：</td>
              <td>
                <input class="inputClass" type="password" name="loginpass" id="loginpass" value="${form.loginpass }"/>
              </td>
              <td>
                <label class="errorClass" id="loginpassError">${errors.loginpass }</label>
              </td>
            </tr>
            <tr>
              <td class="tdText">确认密码：</td>
              <td>
                <input class="inputClass" type="password" name="reloginpass" id="reloginpass" value="${form.reloginpass }"/>
              </td>
              <td>
                <label class="errorClass" id="reloginpassError">${errors.reloginpass}</label>
              </td>
            </tr>
            <tr>
              <td class="tdText">Email：</td>
              <td>
                <input class="inputClass" type="text" name="email" id="email" value="${form.email }"/>
              </td>
              <td>
                <label class="errorClass" id="emailError">${errors.email}</label>
              </td>
            </tr>
            <tr>
              <td class="tdText">验证码：</td>
              <td>
                <input class="inputClass" type="text" name="verifyCode" id="verifyCode" value="${form.verifyCode }"/>
              </td>
              <td>
                <label class="errorClass" id="verifyCodeError">${errors.verifyCode}</label>
              </td>
            </tr>
            <tr>
              <td></td>
              <td>
                <div onclick="javascript:_hyz()" id="divVerifyCode"><img id="imgVerifyCode" src="<c:url value='/VerifyCodeServlet'/>"/></div>
              </td>
              <td>
                <label><a href="javascript:_hyz()">换一张</a></label>
              </td>
            </tr>
            <tr>
              <td></td>
              <td>
                <input type="image" src="<c:url value='/static/images/regist1.jpg'/>" id="submitBtn"/>
              </td>
              <td>
              </td>
            </tr>
          </table>
        </form>
      </div>
    </div>
  </body>
</html>